<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>选择器练习</title>
    <style>
        #gy{
            color: red;
        }
        #zf,#pg{
            color: yellow;
        }
        *{
            border: 1px solid blue;
        }
        #xj,#pg{
            background-color: blue;
        }
        .p2{
            color: deeppink;
        }
        .p1,.p3{
            background-color: chartreuse;
        }
    </style>

</head>
<body>

<ul>
    <li id="lb">刘备</li>
    <li id="gy">关羽</li>
    <li id="zf">张飞</li>
</ul>
<p id="xj">香蕉</p>
<p id="pg">苹果</p>
<input type="text">
<input type="password">
<div>
    <p class="p1">p1</p>
    <div>
        <p class="p2">p2</p>
    </div>
    <div><div><p class="p3">p3</p></div></div>
</div>

</body>
</html>